package com.txby.platformApi.component.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import com.jck.mybatis.mapper.MybatisBaseDaoCRUD;
import com.txby.pf.modules.sys.entity.SysDeptEntity;
import com.txby.pf.modules.sys.service.SysDeptService;
import com.txby.platformCore.entity.SysDeptRegionRelation;
@Service
public class SysDeptRegionRelationService extends MybatisBaseDaoCRUD < SysDeptRegionRelation> {
	@Autowired
	private SysDeptService sysDeptService;
/*
	@Override
//	@GlobalLogAnnotation
	public List findAll(Class clz) {
		List l=super.findAll(clz);
		System.out.println(l);
		return l;
	}
	@GlobalLogAnnotation
	public void findAllTest(Class clz) {
		List l=super.findAll(clz);
		System.out.println(l);
	}
	*/
	
	@Transactional(propagation = Propagation.REQUIRED,timeout=36000,rollbackFor=Exception.class)
	public boolean saveCustomerDept(SysDeptRegionRelation sysDeptRegionRelation,SysDeptEntity dept){
		
	boolean result=false;
	saveObject(sysDeptRegionRelation);
		
		return result;
	}
	
	@Transactional(propagation = Propagation.REQUIRED,timeout=36000,rollbackFor=Exception.class)
	public boolean updateCustomerDept(SysDeptRegionRelation sysDeptRegionRelation){
		boolean result=false;
		
		
		updateObject(sysDeptRegionRelation);
		
		return result;
	}


}
